home *** CD-ROM | disk | FTP | other *** search
/ Halting the Hacker - A P…uide to Computer Security / Halting the Hacker - A Practical Guide to Computer Security.iso / rfc / rfc998.txt < prev    next >
Text File  |  1997-04-01  |  56KB  |  1,238 lines

  1.  
  2. Network Working Group                                     David D. Clark
  3. Request for Comments:  998                               Mark L. Lambert
  4. Obsoletes:  RFC 969                                          Lixia Zhang
  5.                                                                      MIT
  6.                                                               March 1987
  7.  
  8.  
  9.                  NETBLT: A Bulk Data Transfer Protocol
  10.  
  11.  
  12. 1. Status
  13.  
  14.    This document is a description of, and a specification for, the
  15.    NETBLT protocol.  It is a revision of the specification published in
  16.    NIC RFC-969.  The protocol has been revised after extensive research
  17.    into NETBLT's performance over long-delay, high-bandwidth satellite
  18.    channels.  Most of the changes in the protocol specification have to
  19.    do with the computation and use of data timers in a multiple
  20.    buffering data transfer model.
  21.  
  22.    This document is published for discussion and comment, and does not
  23.    constitute a standard.  The proposal may change and certain parts of
  24.    the protocol have not yet been specified; implementation of this
  25.    document is therefore not advised.
  26.  
  27. 2. Introduction
  28.  
  29.    NETBLT (NETwork BLock Transfer) is a transport level protocol
  30.    intended for the rapid transfer of a large quantity of data between
  31.    computers.  It provides a transfer that is reliable and flow
  32.    controlled, and is designed to provide maximum throughput over a wide
  33.    variety of networks.  Although NETBLT currently runs on top of the
  34.    Internet Protocol (IP), it should be able to operate on top of any
  35.    datagram protocol similar in function to IP.
  36.  
  37.    NETBLT's motivation is to achieve higher throughput than other
  38.    protocols might offer.  The protocol achieves this goal by trying to
  39.    minimize the effect of several network-related problems: network
  40.    congestion, delays over satellite links, and packet loss.
  41.  
  42.    Its transmission rate-control algorithms deal well with network
  43.    congestion; its multiple-buffering capability allows high throughput
  44.    over long-delay satellite channels, and its various
  45.    timeout/retransmit algorithms minimize the effect of packet loss
  46.    during a transfer.  Most importantly, NETBLT's features give it good
  47.    performance over long-delay channels without impairing performance
  48.    over high-speed LANs.
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56. Clark, Lambert, & Zhang                                         [Page 1]
  57.  
  58. RFC 998                                                       March 1987
  59.  
  60.  
  61.    The protocol works by opening a connection between two "clients" (the
  62.    "sender" and the "receiver"), transferring the data in a series of
  63.    large data aggregates called "buffers", and then closing the
  64.    connection.  Because the amount of data to be transferred can be very
  65.    large, the client is not required to provide at once all the data to
  66.    the protocol module.  Instead, the data is provided by the client in
  67.    buffers.  The NETBLT layer transfers each buffer as a sequence of
  68.    packets; since each buffer is composed of a large number of packets,
  69.    the per-buffer interaction between NETBLT and its client is far more
  70.    efficient than a per-packet interaction would be.
  71.  
  72.    In its simplest form, a NETBLT transfer works as follows:  the
  73.    sending client loads a buffer of data and calls down to the NETBLT
  74.    layer to transfer it.  The NETBLT layer breaks the buffer up into
  75.    packets and sends these packets across the network in Internet
  76.    datagrams.  The receiving NETBLT layer loads these packets into a
  77.    matching buffer provided by the receiving client.  When the last
  78.    packet in the buffer has arrived, the receiving NETBLT checks to see
  79.    that all packets in that buffer have been correctly received.  If
  80.    some packets are missing, the receiving NETBLT requests that they be
  81.    resent.  When the buffer has been completely transmitted, the
  82.    receiving client is notified by its NETBLT layer.  The receiving
  83.    client disposes of the buffer and provides a new buffer to receive
  84.    more data.  The receiving NETBLT notifies the sender that the new
  85.    buffer is ready, and the sender prepares and sends the next buffer in
  86.    the same manner.  This continues until all the data has been sent; at
  87.    that time the sender notifies the receiver that the transmission has
  88.    been completed.  The connection is then closed.
  89.  
  90.    As described above, the NETBLT protocol is "lock-step".  Action halts
  91.    after a buffer is transmitted, and begins again after confirmation is
  92.    received from the receiver of data.  NETBLT provides for multiple
  93.    buffering, a transfer model in which the sending NETBLT can transmit
  94.    new buffers while earlier buffers are waiting for confirmation from
  95.    the receiving NETBLT.  Multiple buffering makes packet flow
  96.    essentially continuous and markedly improves performance.
  97.  
  98.    The remainder of this document describes NETBLT in detail.  The next
  99.    sections describe the philosophy behind a number of protocol
  100.    features:  packetization, flow control, transfer reliability, and
  101.    connection management. The final sections describe NETBLT's packet
  102.    formats.
  103.  
  104. 3. Buffers and Packets
  105.  
  106.    NETBLT is designed to permit transfer of a very large amounts of data
  107.    between two clients.  During connection setup the sending NETBLT can
  108.    inform the receiving NETBLT of the transfer size; the maximum
  109.    transfer length is 2**32 bytes.  This limit should permit any
  110.    practical application.  The transfer size parameter is for the use of
  111.    the receiving client; the receiving NETBLT makes no use of it.  A
  112.  
  113.  
  114.  
  115. Clark, Lambert, & Zhang                                         [Page 2]
  116.  
  117. RFC 998                                                       March 1987
  118.  
  119.  
  120.    NETBLT receiver accepts data until told by the sender that the
  121.    transfer is complete.
  122.  
  123.    The data to be sent must be broken up into buffers by the client.
  124.    Each buffer must be the same size, save for the last buffer.  During
  125.    connection setup, the sending and receiving NETBLTs negotiate the
  126.    buffer size, based on limits provided by the clients.  Buffer sizes
  127.    are in bytes only; the client is responsible for placing data in
  128.    buffers on byte boundaries.
  129.  
  130.    NETBLT has been designed and should be implemented to work with
  131.    buffers of any size.  The only fundamental limitation on buffer size
  132.    should be the amount of memory available to the client.  Buffers
  133.    should be as large as possible since this minimizes the number of
  134.    buffer transmissions and therefore improves performance.
  135.  
  136.    NETBLT is designed to require a minimum amount of memory, allowing
  137.    the client to allocate as much memory as possible for buffer storage.
  138.    In particular, NETBLT does not keep buffer copies for retransmission
  139.    purposes.  Instead, data to be retransmitted is recopied directly
  140.    from the client buffer.  This means that the client cannot release
  141.    buffer storage piece by piece as the buffer is sent, but this has not
  142.    been a problem in preliminary NETBLT implementations.
  143.  
  144.    Buffers are broken down by the NETBLT layer into sequences of DATA
  145.    packets.  As with the buffer size, the DATA packet size is negotiated
  146.    between the sending and receiving NETBLTs during connection setup.
  147.    Unlike buffer size, DATA packet size is visible only to the NETBLT
  148.    layer.
  149.  
  150.    All DATA packets save the last packet in a buffer must be the same
  151.    size.  Packets should be as large as possible, since NETBLT's
  152.    performance is directly related to packet size.  At the same time,
  153.    the packets should not be so large as to cause internetwork
  154.    fragmentation, since this normally causes performance degradation.
  155.  
  156.    All buffers save the last buffer must be the same size; the last
  157.    buffer can be any size required to complete the transfer.  Since the
  158.    receiving NETBLT does not know the transfer size in advance, it needs
  159.    some way of identifying the last packet in each buffer.  For this
  160.    reason, the last packet of every buffer is not a DATA packet but
  161.    rather an LDATA packet.  DATA and LDATA packets are identical save
  162.    for the packet type.
  163.  
  164. 4. Flow Control
  165.  
  166.    NETBLT uses two strategies for flow control, one internal and one at
  167.    the client level.
  168.  
  169.    The sending and receiving NETBLTs transmit data in buffers; client
  170.    flow control is therefore at a buffer level.  Before a buffer can be
  171.  
  172.  
  173.  
  174. Clark, Lambert, & Zhang                                         [Page 3]
  175.  
  176. RFC 998                                                       March 1987
  177.  
  178.  
  179.    transmitted, NETBLT confirms that both clients have set up matching
  180.    buffers, that one is ready to send data, and that the other is ready
  181.    to receive data.  Either client can therefore control the flow of
  182.    data by not providing a new buffer.  Clients cannot stop a buffer
  183.    transfer once it is in progress.
  184.  
  185.    Since buffers can be quite large, there has to be another method for
  186.    flow control that is used during a buffer transfer.  The NETBLT layer
  187.    provides this form of flow control.
  188.  
  189.    There are several flow control problems that could arise while a
  190.    buffer is being transmitted.  If the sending NETBLT is transferring
  191.    data faster than the receiving NETBLT can process it, the receiver's
  192.    ability to buffer unprocessed packets could be overflowed, causing
  193.    packet loss.  Similarly, a slow gateway or intermediate network could
  194.    cause packets to collect and overflow network packet buffer space.
  195.    Packets will then be lost within the network.  This problem is
  196.    particularly acute for NETBLT because NETBLT buffers will generally
  197.    be quite large, and therefore composed of many packets.
  198.  
  199.    A traditional solution to packet flow control is a window system, in
  200.    which the sending end is permitted to send only a certain number of
  201.    packets at a time.  Unfortunately, flow control using windows tends
  202.    to result in low throughput.  Windows must be kept small in order to
  203.    avoid overflowing hosts and gateways, and cannot easily be updated,
  204.    since an end-to-end exchange is required for each window change.
  205.  
  206.    To permit high throughput over a variety of networks and gateways,
  207.    NETBLT uses a novel flow control method: rate control.  The
  208.    transmission rate is negotiated by the sending and receiving NETBLTs
  209.    during connection setup and after each buffer transmission.  The
  210.    sender uses timers, rather than messages from the receiver, to
  211.    maintain the negotiated rate.
  212.  
  213.    In its simplest form, rate control specifies a minimum time period
  214.    per packet transmission.  This can cause performance problems for
  215.    several reasons.  First, the transmission time for a single packet is
  216.    very small, frequently smaller than the granularity of the timing
  217.    mechanism.  Also, the overhead required to maintain timing mechanisms
  218.    on a per packet basis is relatively high and lowers performance.
  219.  
  220.    The solution is to control the transmission rate of groups of
  221.    packets, rather than single packets.  The sender transmits a burst of
  222.    packets over a negotiated time interval, then sends another burst.
  223.    In this way, the overhead decreases by a factor of the burst size,
  224.    and the per-burst transmission time is long enough that timing
  225.    mechanisms will work properly.  NETBLT's rate control therefore has
  226.    two parts, a burst size and a burst rate, with (burst size)/(burst
  227.    rate) equal to the average transmission time per packet.
  228.  
  229.  
  230.  
  231.  
  232.  
  233. Clark, Lambert, & Zhang                                         [Page 4]
  234.  
  235. RFC 998                                                       March 1987
  236.  
  237.  
  238.    The burst size and burst rate should be based not only on the packet
  239.    transmission and processing speed which each end can handle, but also
  240.    on the capacities of any intermediate gateways or networks.
  241.    Following are some intuitive values for packet size, buffer size,
  242.    burst size, and burst rate.
  243.  
  244.    Packet sizes can be as small as 128 bytes.  Performance with packets
  245.    this small is almost always bad, because of the high per-packet
  246.    processing overhead.  Even the default Internet Protocol packet size
  247.    of 576 bytes is barely big enough for adequate performance.  Most
  248.    networks do not support packet sizes much larger than one or two
  249.    thousand bytes, and packets of this size can also get fragmented when
  250.    traveling over intermediate networks, lowering performance.
  251.  
  252.    The size of a NETBLT buffer is limited only by the amount of memory
  253.    available to a client.  Theoretically, buffers of 100 Kbytes or more
  254.    are possible.  This would mean the transmission of 50 to 100 packets
  255.    per buffer.
  256.  
  257.    The burst size and burst rate are obviously very machine dependent.
  258.    There is a certain amount of transmission overhead in the sending and
  259.    receiving machines associated with maintaining timers and scheduling
  260.    processes.  This overhead can be minimized by sending packets in
  261.    large bursts.  There are also limitations imposed on the burst size
  262.    by the number of available packet buffers in the operating system
  263.    kernel. On most modern operating systems, a burst size of between
  264.    five and ten packets should reduce the overhead to an acceptable
  265.    level.  A preliminary NETBLT implementation for the IBM PC/AT sends
  266.    packets in bursts of five.  It could send more, but is limited by the
  267.    available memory.
  268.  
  269.    The burst rate is in part determined by the granularity of the
  270.    sender's timing mechanism, and in part by the processing speed of the
  271.    receiver and any intermediate gateways.  It is also directly related
  272.    to the burst size.  Burst rates from 20 to 45 milliseconds per 5-
  273.    packet burst have been tried on the IBM PC/AT and Symbolics 3600
  274.    NETBLT implementations with good results within a single local-area
  275.    network.  This value clearly depends on the network bandwidth and
  276.    packet buffering available.
  277.  
  278.    All NETBLT flow control parameters (packet size, buffer size, burst
  279.    size, and burst rate) are negotiated during connection setup.  The
  280.    negotiation process is the same for all parameters.  The client
  281.    initiating the connection (the active end) proposes and sends a set
  282.    of values for each parameter in its connection request.  The other
  283.    client (the passive end) compares these values with the highest-
  284.    performance values it can support.  The passive end can then modify
  285.    any of the parameters, but only by making them more restrictive.  The
  286.    modified parameters are then sent back to the active end in its
  287.    response message.
  288.  
  289.  
  290.  
  291.  
  292. Clark, Lambert, & Zhang                                         [Page 5]
  293.  
  294. RFC 998                                                       March 1987
  295.  
  296.  
  297.    The burst size and burst rate can also be re-negotiated after each
  298.    buffer transmission to adjust the transfer rate according to the
  299.    performance observed from transferring the previous buffer.  The
  300.    receiving end sends burst size and burst rate values in its OK
  301.    messages (described later).  The sender compares these values with
  302.    the values it can support.  Again, it may then modify any of the
  303.    parameters, but only by making them more restrictive.  The modified
  304.    parameters are then communicated to the receiver in a NULL-ACK
  305.    packet, described later.
  306.  
  307.    Obviously each of the parameters depend on many factors -- gateway
  308.    and host processing speeds, available memory, timer granularity --
  309.    some of which cannot be checked by either client.  Each client must
  310.    therefore try to make as best a guess as it can, tuning for
  311.    performance on subsequent transfers.
  312.  
  313. 5. The NETBLT Transfer Model
  314.  
  315.    Each NETBLT transfer has three stages, connection setup, data
  316.    transfer, and connection close.  The stages are described in detail
  317.    below, along with methods for insuring that each stage completes
  318.    reliably.
  319.  
  320. 5.1. Connection Setup
  321.  
  322.    A NETBLT connection is set up by an exchange of two packets between
  323.    the active NETBLT and the passive NETBLT.  Note that either NETBLT
  324.    can send or receive data; the words "active" and "passive" are only
  325.    used to differentiate the end making the connection request from the
  326.    end responding to the connection request.  The active end sends an
  327.    OPEN packet; the passive end acknowledges the OPEN packet in one of
  328.    two ways.  It can either send a REFUSED packet, indicating that the
  329.    connection cannot be completed for some reason, or it can complete
  330.    the connection setup by sending a RESPONSE packet.  At this point the
  331.    transfer can begin.
  332.  
  333.    As discussed in the previous section, the OPEN and RESPONSE packets
  334.    are used to negotiate flow control parameters.  Other parameters used
  335.    in the data transfer are also negotiated.  These parameters are (1)
  336.    the maximum number of buffers that can be sending at any one time,
  337.    and (2) whether or not DATA packet data will be checksummed.  NETBLT
  338.    automatically checksums all non-DATA/LDATA packets.  If the
  339.    negotiated checksum flag is set to TRUE (1), both the header and the
  340.    data of a DATA/LDATA packet are checksummed; if set to FALSE (0),
  341.    only the header is checksummed.  The checksum value is the bitwise
  342.    negation of the ones-complement sum of the 16-bit words being
  343.    checksummed.
  344.  
  345.    Finally, each end transmits its death-timeout value in seconds in
  346.    either the OPEN or the RESPONSE packet.  The death-timeout value will
  347.    be used to determine the frequency with which to send KEEPALIVE
  348.  
  349.  
  350.  
  351. Clark, Lambert, & Zhang                                         [Page 6]
  352.  
  353. RFC 998                                                       March 1987
  354.  
  355.  
  356.    packets during idle periods of an opened connection (death timers and
  357.    KEEPALIVE packets are described in the following section).
  358.  
  359.    The active end specifies a passive client through a client-specific
  360.    "well-known" 16 bit port number on which the passive end listens.
  361.    The active end identifies itself through a 32 bit Internet address
  362.    and a unique 16 bit port number.
  363.  
  364.    In order to allow the active and passive ends to communicate
  365.    miscellaneous useful information, an unstructured, variable-length
  366.    field is provided in OPEN and RESPONSE packets for any client-
  367.    specific information that may be required.  In addition, a "reason
  368.    for refusal" field is provided in REFUSED packets.
  369.  
  370.    Recovery for lost OPEN and RESPONSE packets is provided by the use of
  371.    timers.  The active end sets a timer when it sends an OPEN packet.
  372.    When the timer expires, another OPEN packet is sent, until some
  373.    predetermined maximum number of OPEN packets have been sent.  The
  374.    timer is cleared upon receipt of a RESPONSE packet.
  375.  
  376.    To prevent duplication of OPEN and RESPONSE packets, the OPEN packet
  377.    contains a 32 bit connection unique ID that must be returned in the
  378.    RESPONSE packet.  This prevents the initiator from confusing the
  379.    response to the current request with the response to an earlier
  380.    connection request (there can only be one connection between any two
  381.    ports).  Any OPEN or RESPONSE packet with a destination port matching
  382.    that of an open connection has its unique ID checked.  If the unique
  383.    ID of the packet matches the unique ID of the connection, then the
  384.    packet type is checked.  If it is a RESPONSE packet, it is treated as
  385.    a duplicate and ignored.  If it is an OPEN packet, the passive NETBLT
  386.    sends another RESPONSE (assuming that a previous RESPONSE packet was
  387.    sent and lost, causing the initiating NETBLT to retransmit its OPEN
  388.    packet).  A non-matching unique ID must be treated as an attempt to
  389.    open a second connection between the same port pair and is rejected
  390.    by sending an ABORT message.
  391.  
  392. 5.2. Data Transfer
  393.  
  394.    The simplest model of data transfer proceeds as follows.  The sending
  395.    client sets up a buffer full of data.  The receiving NETBLT sends a
  396.    GO message inside a CONTROL packet to the sender, signifying that it
  397.    too has set up a buffer and is ready to receive data.  Once the GO
  398.    message is received, the sender transmits the buffer as a series of
  399.    DATA packets followed by an LDATA packet.  When the last packet in
  400.    the buffer has been received, the receiver sends a RESEND message
  401.    inside a CONTROL packet containing a list of packets that were not
  402.    received.  The sender resends these packets.  This process continues
  403.    until there are no missing packets.  At that time the receiver sends
  404.    an OK message inside a CONTROL packet, sets up another buffer to
  405.    receive data, and sends another GO message.  The sender, having
  406.    received the OK message, sets up another buffer, waits for the GO
  407.  
  408.  
  409.  
  410. Clark, Lambert, & Zhang                                         [Page 7]
  411.  
  412. RFC 998                                                       March 1987
  413.  
  414.  
  415.    message, and repeats the process.
  416.  
  417.    The above data transfer model is effectively a lock-step protocol,
  418.    and causes time to be wasted while the sending NETBLT waits for
  419.    permission to send a new buffer.  A more efficient transfer model
  420.    uses multiple buffering to increase performance.  Multiple buffering
  421.    is a technique in which the sender and receiver allocate and transmit
  422.    buffers in a manner that allows error recovery or successful
  423.    transmission confirmation of previous buffers to be concurrent with
  424.    transmission of the current buffer.
  425.  
  426.    During the connection setup phase, one of the negotiated parameters
  427.    is the number of concurrent buffers permitted during the transfer.
  428.    If there is more than one buffer available, transfer of the next
  429.    buffer may start right after the current buffer finishes.  This is
  430.    illustrated in the following example:
  431.  
  432.    Assume two buffers A and B in a multiple-buffer transfer, with A
  433.    preceding B. When A has been transferred and the sending NETBLT is
  434.    waiting for either an OK or a RESEND message for it, the sending
  435.    NETBLT can start sending B immediately, keeping data flowing at a
  436.    stable rate.  If the receiver of data sends an OK for A, all is well;
  437.    if it receives a RESEND, the missing packets specified in the RESEND
  438.    message are retransmitted.
  439.  
  440.    In the multiple-buffer transfer model, all packets to be sent are
  441.    re-ordered by buffer number (lowest number first), with the transfer
  442.    rate specified by the burst size and burst rate.  Since buffer
  443.    numbers increase monotonically, packets from an earlier buffer will
  444.    always precede packets from a later buffer.
  445.  
  446.    Having several buffers transmitting concurrently is actually not that
  447.    much more complicated than transmitting a single buffer at a time.
  448.    The key is to visualize each buffer as a finite state machine;
  449.    several buffers are merely a group of finite state machines, each in
  450.    one of several states.  The transfer process consists of moving
  451.    buffers through various states until the entire transmission has
  452.    completed.
  453.  
  454.    There are several obvious flaws in the data transfer model as
  455.    described above.  First, what if the GO, OK, or RESEND messages are
  456.    lost?  The sender cannot act on a packet it has not received, so the
  457.    protocol will hang.  Second, if an LDATA packet is lost, how does the
  458.    receiver know when the buffer has been transmitted?  Solutions for
  459.    each of these problems are presented below.
  460.  
  461. 5.2.1. Recovering from Lost Control Messages
  462.  
  463.    NETBLT solves the problem of lost OK, GO, and RESEND messages in two
  464.    ways.  First, it makes use of a control timer.  The receiver can send
  465.    one or more control messages (OK, GO, or RESEND) within a single
  466.  
  467.  
  468.  
  469. Clark, Lambert, & Zhang                                         [Page 8]
  470.  
  471. RFC 998                                                       March 1987
  472.  
  473.  
  474.    CONTROL packet.  Whenever the receiver sends a control packet, it
  475.    sets a control timer.  This timer is either "reset" (set again) or
  476.    "cleared" (deactivated), under the following conditions:
  477.  
  478.    When the control timer expires, the receiving NETBLT resends the
  479.    control packet and resets the timer.  The receiving NETBLT continues
  480.    to resend control packets in response to control timer's expiration
  481.    until either the control timer is cleared or the receiving NETBLT's
  482.    death timer (described later) expires (at which time it shuts down
  483.    the connection).
  484.  
  485.    Each control message includes a sequence number which starts at one
  486.    and increases by one for each control message sent.  The sending
  487.    NETBLT checks the sequence number of every incoming control message
  488.    against all other sequence numbers it has received.  It stores the
  489.    highest sequence number below which all other received sequence
  490.    numbers are consecutive (in following paragraphs this is called the
  491.    high-acknowledged-sequence-number) and returns this number in every
  492.    packet flowing back to the receiver.  The receiver is permitted to
  493.    clear its control timer when it receives a packet from the sender
  494.    with a high-acknowledged-sequence-number greater than or equal to the
  495.    highest sequence number in the control packet just sent.
  496.  
  497.    Ideally, a NETBLT implementation should be able to cope with out-of-
  498.    sequence control messages, perhaps collecting them for later
  499.    processing, or even processing them immediately.  If an incoming
  500.    control message "fills" a "hole" in a group of message sequence
  501.    numbers, the implementation could even be clever enough to detect
  502.    this and adjust its outgoing sequence value accordingly.
  503.  
  504.    The sending NETBLT, upon receiving a CONTROL packet, should act on
  505.    the packet as quickly as possible.  It either sets up a new buffer
  506.    (upon receipt of an OK message for a previous buffer), marks data for
  507.    resending (upon receipt of a RESEND message), or prepares a buffer
  508.    for sending (upon receipt of a GO message).  If the sending NETBLT is
  509.    not in a position to send data, it should send a NULL-ACK packet,
  510.    which contains its high-acknowledged-sequence-number (this permits
  511.    the receiving NETBLT to acknowledge any outstanding control
  512.    messages), and wait until it can send more data.  In all of these
  513.    cases, the system overhead for a response to the incoming control
  514.    message should be small and relatively constant.
  515.  
  516.    The small amount of message-processing overhead allows accurate
  517.    control timers to be set for all types of control messages with a
  518.    single, simple algorithm -- the network round-trip transit time, plus
  519.    a variance factor.  This is more efficient than schemes used by other
  520.    protocols, where timer value calculation has been a problem because
  521.    the processing time for a particular packet can vary greatly
  522.    depending on the packet type.
  523.  
  524.    Control timer value estimation is extremely important in a high-
  525.  
  526.  
  527.  
  528. Clark, Lambert, & Zhang                                         [Page 9]
  529.  
  530. RFC 998                                                       March 1987
  531.  
  532.  
  533.    performance protocol like NETBLT.  A long control timer causes the
  534.    receiving NETBLT to wait for long periods of time before
  535.    retransmitting unacknowledged messages.  A short control timer value
  536.    causes the sending NETBLT to receive many duplicate control messages
  537.    (which it can reject, but which takes time).
  538.  
  539.    In addition to the use of control timers, NETBLT reduces lost control
  540.    messages by using a single long-lived control packet; the packet is
  541.    treated like a FIFO queue, with new control messages added on at the
  542.    end and acknowledged control messages removed from the front.  The
  543.    implementation places control messages in the control packet and
  544.    transmits the entire control packet, consisting of any unacknowledged
  545.    control messages plus new messages just added.  The entire control
  546.    packet is also transmitted whenever the control timer expires.  Since
  547.    control packet transmissions are fairly frequent, unacknowledged
  548.    messages may be transmitted several times before they are finally
  549.    acknowledged.  This redundant transmission of control messages
  550.    provides automatic recovery for most control message losses over a
  551.    noisy channel.
  552.  
  553.    This scheme places some burdens on the receiver of the control
  554.    messages.  It must be able to quickly reject duplicate control
  555.    messages, since a given message may be retransmitted several times
  556.    before its acknowledgement is received and it is removed from the
  557.    control packet.  Typically this is fairly easy to do; the sender of
  558.    data merely throws away any control messages with sequence numbers
  559.    lower than its high-acknowledged-sequence-number.
  560.  
  561.    Another problem with this scheme is that the control packet may
  562.    become larger than the maximum allowable packet size if too many
  563.    control messages are placed into it.  This has not been a problem in
  564.    the current NETBLT implementations: a typical control packet size is
  565.    1000 bytes; RESEND control messages average about 20 bytes in length,
  566.    GO messages are 8 bytes long, and OK messages are 16 bytes long.
  567.    This allows 50-80 control messages to be placed in the control
  568.    packet, more than enough for reasonable transfers.  Other
  569.    implementations can provide for multiple control packets if a single
  570.    control packet may not be sufficient.
  571.  
  572.    The control timer value must be carefully estimated.  It can have as
  573.    its initial value an arbitrary number.  Subsequent control packets
  574.    should have their timer values based on the network round-trip
  575.    transit time (i.e. the time between sending the control packet and
  576.    receiving the acknowledgment of all messages in the control packet)
  577.    plus a variance factor.  The timer value should be continually
  578.    updated, based on a smoothed average of collected round-trip transit
  579.    times.
  580.  
  581.  
  582.  
  583.  
  584.  
  585.  
  586.  
  587. Clark, Lambert, & Zhang                                        [Page 10]
  588.  
  589. RFC 998                                                       March 1987
  590.  
  591.  
  592. 5.2.2. Recovering from Lost LDATA Packets
  593.  
  594.    NETBLT solves the problem of LDATA packet loss by using a data timer
  595.    for each buffer at the receiving end.  The simplest data timer model
  596.    has a data timer set when a buffer is ready to be received; if the
  597.    data timer expires, the receiving NETBLT assumes a lost LDATA packet
  598.    and sends a RESEND message requesting all missing DATA packets in the
  599.    buffer.  When all packets have been received, the timer is cleared.
  600.  
  601.    Data timer values are not based on network round-trip transit time;
  602.    instead they are based on the amount of time taken to transfer a
  603.    buffer (as determined by the number of DATA packet bursts in the
  604.    buffer times the burst rate) plus a variance factor <1>.
  605.  
  606.    Obviously an accurate estimation of the data timer value is very
  607.    important.  A short data timer value causes the receiving NETBLT to
  608.    send unnecessary RESEND packets.  This causes serious performance
  609.    degradation since the sending NETBLT has to stop what it is doing and
  610.    resend a number of DATA packets.
  611.  
  612.    Data timer setting and clearing turns out to be fairly complicated,
  613.    particularly in a multiple-buffering transfer model.  In
  614.    understanding how and when data timers are set and cleared, it is
  615.    helpful to visualize each buffer as a finite-state machine and take a
  616.    look at the various states.
  617.  
  618.    The state sequence for a sending buffer is simple.  When a GO message
  619.    for the buffer is received, the buffer is created, filled with data,
  620.    and placed in a SENDING state.  When an OK for that buffer has been
  621.    received, it goes into a SENT state and is disposed of.
  622.  
  623.    The state sequence for a receiving buffer is a little more
  624.    complicated.  Assume existence of a buffer A. When a control message
  625.    for A is sent, the buffer moves into state ACK-WAIT (it is waiting
  626.    for acknowledgement of the control message).
  627.  
  628.    As soon as the control message has been acknowledged, buffer A moves
  629.    from the ACK-WAIT state into the ACKED state (it is now waiting for
  630.    DATA packets to arrive).  At this point, A's data timer is set and
  631.    the control message removed from the control packet.  Estimation of
  632.    the data timer value at this point is quite difficult.  In a
  633.    multiple-buffer transfer model, the receiving NETBLT can send several
  634.    GO messages at once.  A single DATA packet from the sending NETBLT
  635.    could acknowledge all the GO messages, causing several buffers to
  636.    start up data timers.  Clearly each of the data timers must be set in
  637.    a manner that takes into account each buffer's place in the order of
  638.    transmission.  Packets for a buffer A - 1 will always be transmitted
  639.    before packets in A, so A's data timer must take into account the
  640.    arrival of all of A - 1's DATA packets as well as arrival of its own
  641.    DATA packets.  This means that the timer values become increasingly
  642.    less accurate for higher-numbered buffers.  Because this data timer
  643.  
  644.  
  645.  
  646. Clark, Lambert, & Zhang                                        [Page 11]
  647.  
  648. RFC 998                                                       March 1987
  649.  
  650.  
  651.    value can be quite inaccurate, it is called a "loose" data timer.
  652.    The loose data timer value is recalculated later (using the same
  653.    algorithm, but with updated information), giving a "tight" timer, as
  654.    described below.
  655.  
  656.    When the first DATA packet for A arrives, A moves from the ACKED
  657.    state to the RECEIVING state and its data timer is set to a new
  658.    "tight" value.  The tight timer value is calculated in the same
  659.    manner as the loose timer, but it is more accurate since we have
  660.    moved forward in time and those buffers numbered lower than A have
  661.    presumably been dealt with (or their packets would have arrived
  662.    before A's), leaving fewer packets to arrive between the setting of
  663.    the data timer and the arrival of the last DATA packet in A.
  664.  
  665.    The receiving NETBLT also sets the tight data timers of any buffers
  666.    numbered lower than A that are also in the ACKED state.  This is done
  667.    as an optimization: we know that buffers are processed in order,
  668.    lowest number first.  If a buffer B numbered lower than A is in the
  669.    ACKED state, its DATA packets should arrive before A's.  Since A's
  670.    have arrived first, B's must have gotten lost.  Since B's loose data
  671.    timer has not expired (it would then have sent a RESEND message and
  672.    be in the ACK-WAIT state), we set the tight timer, allowing the
  673.    missing packets to be detected earlier.  An immediate RESEND is not
  674.    sent because it is possible that A's packet was re-ordered before B's
  675.    by the network, and that B's packets may arrive shortly.
  676.  
  677.    When all DATA packets for A have been received, it moves from the
  678.    RECEIVING state to the RECEIVED state and is disposed of.  Had any
  679.    packets been missing, A's data timer would have expired and A would
  680.    have moved into the ACK-WAIT state after sending a RESEND message.
  681.    The state progression would then move as in the above example.
  682.  
  683.    The control and data timer system can be summarized as follows:
  684.    normally, the receiving NETBLT is working under one of two types of
  685.    timers, a control timer or a data timer.  There is one data timer per
  686.    buffer transmission and one control timer per control packet.  The
  687.    data timer is active while its buffer is in either the ACKED (loose
  688.    data timer value is used) or the RECEIVING (tight data timer value is
  689.    used) states; a control timer is active whenever the receiving NETBLT
  690.    has any unacknowledged control messages in its control packet.
  691.  
  692. 5.2.3. Death Timers and Keepalive Packets
  693.  
  694.    The above system still leaves a few problems.  If the sending NETBLT
  695.    is not ready to send, it sends a single NULL-ACK packet to clear any
  696.    outstanding control timers at the receiving end.  After this the
  697.    receiver will wait.  The sending NETBLT could die and the receiver,
  698.    with its control timer cleared, would hang.  Also, the above system
  699.    puts timers only on the receiving NETBLT.  The sending NETBLT has no
  700.    timers; if the receiving NETBLT dies, the sending NETBLT will hang
  701.    while waiting for control messages to arrive.
  702.  
  703.  
  704.  
  705. Clark, Lambert, & Zhang                                        [Page 12]
  706.  
  707. RFC 998                                                       March 1987
  708.  
  709.  
  710.    The solution to the above two problems is the use of a death timer
  711.    and a keepalive packet for both the sending and receiving NETBLTs.
  712.    As soon as the connection is opened, each end sets a death timer;
  713.    this timer is reset every time a packet is received.  When a NETBLT's
  714.    death timer expires, it can assume the other end has died and can
  715.    close the connection.
  716.  
  717.    It is possible that the sending or receiving NETBLTs will have to
  718.    wait for long periods while their respective clients get buffer space
  719.    and load their buffers with data.  Since a NETBLT waiting for buffer
  720.    space is in a perfectly valid state, the protocol must have some
  721.    method for preventing the other end's death timer from expiring.  The
  722.    solution is to use a KEEPALIVE packet, which is sent repeatedly at
  723.    fixed intervals when a NETBLT cannot send other packets.  Since the
  724.    death timer is reset whenever a packet is received, it will never
  725.    expire as long as the other end sends packets.
  726.  
  727.    The frequency with which KEEPALIVE packets are transmitted is
  728.    computed as follows:  At connection startup, each NETBLT chooses a
  729.    death-timer value and sends it to the other end in either the OPEN or
  730.    the RESPONSE packet.  The other end takes the death-timeout value and
  731.    uses it to compute a frequency with which to send KEEPALIVE packets.
  732.    The KEEPALIVE frequency should be high enough that several KEEPALIVE
  733.    packets can be lost before the other end's death timer expires (e.g.
  734.    death timer value divided by four).
  735.  
  736.    The death timer value is relatively easy to estimate.  Since it is
  737.    continually reset, it need not be based on the transfer size.
  738.    Instead, it should be based at least in part on the type of
  739.    application using NETBLT.  User applications should have smaller
  740.    death timeout values to avoid forcing humans to wait long periods of
  741.    time for a death timeout to occur.  Machine applications can have
  742.    longer timeout values.
  743.  
  744. 5.3. Closing the Connection
  745.  
  746.    There are three ways to close a connection: a connection close, a
  747.    "quit", or an "abort".
  748.  
  749. 5.3.1. Successful Transfer
  750.  
  751.    After a successful data transfer, NETBLT closes the connection.  When
  752.    the sender is transmitting the last buffer of data, it sets a "last-
  753.    buffer" flag on every DATA packet in the buffer.  This means that no
  754.    NEW data will be transmitted.  The receiver knows the transfer has
  755.    completed successfully when all of the following are true: (1) it has
  756.    received DATA packets with a "last-buffer" flag set, (2) all its
  757.    control messages have been acknowledged, and (3) it has no
  758.    outstanding buffers with missing packets.  At that point, the
  759.    receiver is permitted to close its half of the connection.  The
  760.    sender knows the transfer has completed when the following are true:
  761.  
  762.  
  763.  
  764. Clark, Lambert, & Zhang                                        [Page 13]
  765.  
  766. RFC 998                                                       March 1987
  767.  
  768.  
  769.    (1) it has transmitted DATA packets with a "last-buffer" flag set and
  770.    (2) it has received OK messages for all its buffers.  At that point,
  771.    it "dallies" for a predetermined period of time before closing its
  772.    half of the connection.  If the NULL-ACK packet acknowledging the
  773.    receiver's last OK message was lost, the receiver has time to
  774.    retransmit the OK message, receive a new NULL-ACK, and recognize a
  775.    successful transfer.  The dally timer value MUST be based on the
  776.    receiver's control timer value; it must be long enough to allow the
  777.    receiver's control timer to expire so that the OK message can be re-
  778.    sent.  For this reason, all OK messages contain (in addition to new
  779.    burst size and burst rate values), the receiver's current control
  780.    timer value in milliseconds.  The sender uses this value to compute
  781.    its dally timer value.
  782.  
  783.    Since the dally timer value may be quite large, the receiving NETBLT
  784.    is permitted to "short-circuit" the sending NETBLT's dally timer by
  785.    transmitting a DONE packet.  The DONE packet is transmitted when the
  786.    receiver knows the transfer has been successfully completed.  When
  787.    the sender receives a DONE packet, it is allowed to clear its dally
  788.    timer and close its half of the connection immediately.  The DONE
  789.    packet is not reliably transmitted, since failure to receive it only
  790.    means that the sending NETBLT will take longer time to close its half
  791.    of the connection (as it waits for its dally timer to clear)
  792.  
  793. 5.3.2. Client QUIT
  794.  
  795.    During a NETBLT transfer, one client may send a QUIT packet to the
  796.    other if it thinks that the other client is malfunctioning.  Since
  797.    the QUIT occurs at a client level, the QUIT transmission can only
  798.    occur between buffer transmissions.  The NETBLT receiving the QUIT
  799.    packet can take no action other than immediately notifying its client
  800.    and transmitting a QUITACK packet.  The QUIT sender must time out and
  801.    retransmit until a QUITACK has been received or its death timer
  802.    expires.  The sender of the QUITACK dallies before quitting, so that
  803.    it can respond to a retransmitted QUIT.
  804.  
  805. 5.3.3. NETBLT ABORT
  806.  
  807.    An ABORT takes place when a NETBLT layer thinks that it or its
  808.    opposite is malfunctioning.  Since the ABORT originates in the NETBLT
  809.    layer, it can be sent at any time.  The ABORT implies that the NETBLT
  810.    layer is malfunctioning, so no transmit reliability is expected, and
  811.    the sender can immediately close it connection.
  812.  
  813. 6. Protocol Layering Structure
  814.  
  815.    NETBLT is implemented directly on top of the Internet Protocol (IP).
  816.    It has been assigned an official protocol number of 30 (decimal).
  817.  
  818.  
  819.  
  820.  
  821.  
  822.  
  823. Clark, Lambert, & Zhang                                        [Page 14]
  824.  
  825. RFC 998                                                       March 1987
  826.  
  827.  
  828. 7. Planned Enhancements
  829.  
  830.    As currently specified, NETBLT has no algorithm for determining its
  831.    rate-control parameters (burst rate, burst size, etc.).  In initial
  832.    performance testing, these parameters have been set by the person
  833.    performing the test.  We are now exploring ways to have NETBLT set
  834.    and adjust its rate-control parameters automatically.
  835.  
  836. 8. Packet Formats
  837.  
  838.    NETBLT packets are divided into three categories, all of which share
  839.    a common packet header.  First, there are those packets that travel
  840.    only from data sender to receiver; these contain the high-
  841.    acknowledged-sequence-numbers which the receiver uses for control
  842.    message transmission reliability.  These packets are the NULL-ACK,
  843.    DATA, and LDATA packets.  Second, there is a packet that travels only
  844.    from receiver to sender.  This is the CONTROL packet; each CONTROL
  845.    packet can contain an arbitrary number of control messages (GO, OK,
  846.    or RESEND), each with its own sequence number.  Finally, there are
  847.    those packets which either have special ways of insuring reliability,
  848.    or are not reliably transmitted.  These are the OPEN, RESPONSE,
  849.    REFUSED, QUIT, QUITACK, DONE, KEEPALIVE, and ABORT packets.  Of
  850.    these, all save the DONE packet can be sent by both sending and
  851.    receiving NETBLTs.
  852.  
  853.    All packets are "longword-aligned", i.e. all packets are a multiple
  854.    of 4 bytes in length and all 4-byte fields start on a longword
  855.    boundary.  All arbitrary-length string fields are terminated with at
  856.    least one null byte, with extra null bytes added at the end to create
  857.    a field that is a multiple of 4 bytes long.
  858.  
  859.  
  860.  
  861.  
  862.  
  863.  
  864.  
  865.  
  866.  
  867.  
  868.  
  869.  
  870.  
  871.  
  872.  
  873.  
  874.  
  875.  
  876.  
  877.  
  878.  
  879.  
  880.  
  881.  
  882. Clark, Lambert, & Zhang                                        [Page 15]
  883.  
  884. RFC 998                                                       March 1987
  885.  
  886.  
  887.    Packet Formats for NETBLT
  888.  
  889.    OPEN (type 0) and RESPONSE (type 1):
  890.  
  891.                       1                   2                   3
  892.     1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2
  893.    +---------------+---------------+---------------+---------------+
  894.    |           Checksum            |    Version    |     Type      |
  895.    +---------------+---------------+---------------+---------------+
  896.    |           Length              |           Local Port          |
  897.    +---------------+---------------+---------------+---------------+
  898.    |        Foreign Port           | Longword Alignment Padding    |
  899.    +---------------+---------------+---------------+---------------+
  900.    |                       Connection Unique ID                    |
  901.    +---------------+---------------+---------------+---------------+
  902.    |                         Buffer Size                           |
  903.    +---------------+---------------+---------------+---------------+
  904.    |                       Transfer Size                           |
  905.    +---------------+---------------+---------------+---------------+
  906.    |        DATA packet size       |          Burst Size           |
  907.    +---------------+---------------+---------------+---------------+
  908.    |           Burst Rate          |       Death Timer Value       |
  909.    +---------------+---------------+---------------+---------------+
  910.    |       Reserved (MBZ)      |C|M| Maximum # Outstanding Buffers |
  911.    +---------------+---------------+---------------+---------------+
  912.    | Client String ...
  913.    +---------------+---------------+---------------
  914.                                      Longword Alignment Padding    |
  915.                     ---------------+-------------------------------+
  916.  
  917.    Checksum: packet checksum (algorithm is described in the section
  918.    "Connection Setup")
  919.  
  920.    Version: the NETBLT protocol version number
  921.  
  922.    Type: the NETBLT packet type number (OPEN = 0, RESPONSE = 1,
  923.    etc.)
  924.  
  925.    Length: the total length (NETBLT header plus data, if present)
  926.    of the NETBLT packet in bytes
  927.  
  928.    Local Port: the local NETBLT's 16-bit port number
  929.  
  930.    Foreign Port: the foreign NETBLT's 16-bit port number
  931.  
  932.    Connection UID: the 32 bit connection UID specified in the
  933.    section "Connection Setup".
  934.  
  935.    Buffer size: the size in bytes of each NETBLT buffer (save the
  936.    last)
  937.  
  938.  
  939.  
  940.  
  941. Clark, Lambert, & Zhang                                        [Page 16]
  942.  
  943. RFC 998                                                       March 1987
  944.  
  945.  
  946.    Transfer size: (optional) the size in bytes of the transfer.
  947.  
  948.    This is for client information only; the receiving NETBLT should
  949.    NOT make use of it.
  950.  
  951.    Data packet size: length of each DATA packet in bytes
  952.  
  953.    Burst Size: Number of DATA packets in a burst
  954.  
  955.    Burst Rate: Transmit time in milliseconds of a single burst
  956.  
  957.    Death timer: Packet sender's death timer value in seconds
  958.  
  959.    "M": the transfer mode (0 = READ, 1 = WRITE)
  960.  
  961.    "C": the DATA packet data checksum flag (0 = do not checksum
  962.    DATA packet data, 1 = do)
  963.  
  964.    Maximum Outstanding Buffers: maximum number of buffers that can
  965.    be transferred before waiting for an OK message from the
  966.    receiving NETBLT.
  967.  
  968.    Client string: an arbitrary, null-terminated, longword-aligned
  969.    string for use by NETBLT clients.
  970.  
  971.    KEEPALIVE (type 2), QUITACK (type 4), and DONE (type 11)
  972.  
  973.                       1                   2                   3
  974.     1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2
  975.    +---------------+---------------+---------------+---------------+
  976.    |           Checksum            |    Version    |     Type      |
  977.    +---------------+---------------+---------------+---------------+
  978.    |           Length              |           Local Port          |
  979.    +---------------+---------------+---------------+---------------+
  980.    |        Foreign Port           | Longword Alignment Padding    |
  981.    +---------------+---------------+---------------+---------------+
  982.  
  983.  
  984.  
  985.  
  986.  
  987.  
  988.  
  989.  
  990.  
  991.  
  992.  
  993.  
  994.  
  995.  
  996.  
  997.  
  998.  
  999.  
  1000. Clark, Lambert, & Zhang                                        [Page 17]
  1001.  
  1002. RFC 998                                                       March 1987
  1003.  
  1004.  
  1005.    QUIT (type 3), ABORT (type 5), and REFUSED (type 10)
  1006.  
  1007.                       1                   2                   3
  1008.     1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2
  1009.    +---------------+---------------+---------------+---------------+
  1010.    |           Checksum            |    Version    |     Type      |
  1011.    +---------------+---------------+---------------+---------------+
  1012.    |           Length              |           Local Port          |
  1013.    +---------------+---------------+---------------+---------------+
  1014.    |        Foreign Port           | Longword Alignment Padding    |
  1015.    +---------------+---------------+---------------+---------------+
  1016.    | Reason for QUIT/ABORT/REFUSE...
  1017.    +---------------+---------------+---------------
  1018.                                      Longword Alignment Padding    |
  1019.                     ---------------+-------------------------------+
  1020.  
  1021.    DATA (type 6) and LDATA (type 7):
  1022.  
  1023.                       1                   2                   3
  1024.     1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2
  1025.    +---------------+---------------+---------------+---------------+
  1026.    |           Checksum            |    Version    |     Type      |
  1027.    +---------------+---------------+---------------+---------------+
  1028.    |           Length              |           Local Port          |
  1029.    +---------------+---------------+---------------+---------------+
  1030.    |        Foreign Port           | Longword Alignment Padding    |
  1031.    +---------------+---------------+---------------+---------------+
  1032.    |                       Buffer Number                           |
  1033.    +---------------+---------------+---------------+---------------+
  1034.    | High Consecutive Seq Num Rcvd |         Packet Number         |
  1035.    +---------------+---------------+---------------+---------------+
  1036.    |    Data Area Checksum Value   |      Reserved (MBZ)         |L|
  1037.    +---------------+---------------+---------------+---------------+
  1038.  
  1039.    Buffer number: a 32 bit unique number assigned to every buffer.
  1040.    Numbers are monotonically increasing.
  1041.  
  1042.    High Consecutive Sequence Number Received: Highest control
  1043.    message sequence number below which all sequence numbers received
  1044.    are consecutive.
  1045.  
  1046.    Packet number: monotonically increasing DATA packet identifier
  1047.  
  1048.    Data Area Checksum Value: Checksum of the DATA packet's data.
  1049.    Algorithm used is the same as that used to compute checksums of
  1050.    other NETBLT packets.
  1051.  
  1052.    "L" is a flag set when the buffer that this DATA packet belongs
  1053.    to is the last buffer in the transfer.
  1054.  
  1055.  
  1056.  
  1057.  
  1058.  
  1059. Clark, Lambert, & Zhang                                        [Page 18]
  1060.  
  1061. RFC 998                                                       March 1987
  1062.  
  1063.  
  1064.    NULL-ACK (type 8)
  1065.  
  1066.                       1                   2                   3
  1067.     1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2
  1068.    +---------------+---------------+---------------+---------------+
  1069.    |           Checksum            |    Version    |     Type      |
  1070.    +---------------+---------------+---------------+---------------+
  1071.    |           Length              |           Local Port          |
  1072.    +---------------+---------------+---------------+---------------+
  1073.    |        Foreign Port           | Longword Alignment Padding    |
  1074.    +---------------+---------------+---------------+---------------+
  1075.    | High Consecutive Seq Num Rcvd |        New Burst Size         |
  1076.    +---------------+---------------+---------------+---------------+
  1077.    |       New Burst Rate          |  Longword Alignment Padding   |
  1078.    +---------------+---------------+---------------+---------------+
  1079.  
  1080.    High Consecutive Sequence Number Received: same as in DATA/LDATA
  1081.    packet
  1082.  
  1083.    New Burst Size:  Burst size as negotiated from value given by
  1084.    receiving NETBLT in OK message
  1085.  
  1086.    New burst rate: Burst rate as negotiated from value given
  1087.    by receiving NETBLT in OK message.  Value is in milliseconds.
  1088.  
  1089.    CONTROL (type 9):
  1090.  
  1091.                       1                   2                   3
  1092.     1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2
  1093.    +---------------+---------------+---------------+---------------+
  1094.    |           Checksum            |    Version    |     Type      |
  1095.    +---------------+---------------+---------------+---------------+
  1096.    |           Length              |           Local Port          |
  1097.    +---------------+---------------+---------------+---------------+
  1098.    |        Foreign Port           | Longword Alignment Padding    |
  1099.    +---------------+---------------+---------------+---------------+
  1100.  
  1101.    Followed by any number of messages, each of which is longword
  1102.    aligned, with the following formats:
  1103.  
  1104.    GO message (type 0):
  1105.  
  1106.                       1                   2                   3
  1107.     1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2
  1108.    +---------------+---------------+---------------+---------------+
  1109.    |    Type       | Word Padding  |       Sequence Number         |
  1110.    +---------------+---------------+---------------+---------------+
  1111.    |                        Buffer Number                          |
  1112.    +---------------+---------------+---------------+---------------+
  1113.  
  1114.    Type: message type (GO = 0, OK = 1, RESEND = 2)
  1115.  
  1116.  
  1117.  
  1118. Clark, Lambert, & Zhang                                        [Page 19]
  1119.  
  1120. RFC 998                                                       March 1987
  1121.  
  1122.  
  1123.    Sequence number: A 16 bit unique message number.  Sequence
  1124.    numbers must be monotonically increasing, starting from 1.
  1125.  
  1126.    Buffer number: as in DATA/LDATA packet
  1127.  
  1128.    OK message (type 1):
  1129.  
  1130.                       1                   2                   3
  1131.     1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2
  1132.    +---------------+---------------+---------------+---------------+
  1133.    |    Type       | Word Padding  |       Sequence Number         |
  1134.    +---------------+---------------+---------------+---------------+
  1135.    |                        Buffer Number                          |
  1136.    +---------------+---------------+---------------+---------------+
  1137.    |    New Offered Burst Size     |   New Offered Burst Rate      |
  1138.    +---------------+---------------+---------------+---------------+
  1139.    | Current control timer value   | Longword Alignment Padding    |
  1140.    +---------------+---------------+---------------+---------------+
  1141.  
  1142.    New offered burst size: burst size for subsequent buffer
  1143.    transfers, possibly based on performance information for previous
  1144.    buffer transfers.
  1145.  
  1146.    New offered burst rate: burst rate for subsequent buffer
  1147.    transfers, possibly based on performance information for previous
  1148.    buffer transfers.  Rate is in milliseconds.
  1149.  
  1150.    Current control timer value: Receiving NETBLT's control timer
  1151.    value in milliseconds.
  1152.  
  1153.    RESEND Message (type 2):
  1154.  
  1155.                       1                   2                   3
  1156.     1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2
  1157.    +---------------+---------------+---------------+---------------+
  1158.    |    Type       | Word Padding  |       Sequence Number         |
  1159.    +---------------+---------------+---------------+---------------+
  1160.    |                        Buffer Number                          |
  1161.    +---------------+---------------+---------------+---------------+
  1162.    |  Number of Missing Packets    | Longword Alignment Padding    |
  1163.    +---------------+---------------+---------------+---------------+
  1164.    |       Packet Number (2 bytes) ...
  1165.    +---------------+---------------+----------
  1166.                                    |    Padding (if necessary)     |
  1167.                         -----------+---------------+---------------+
  1168.  
  1169.    Packet number:  the 16 bit data packet identifier found in each
  1170.    DATA packet.
  1171.  
  1172.  
  1173.  
  1174.  
  1175.  
  1176.  
  1177. Clark, Lambert, & Zhang                                        [Page 20]
  1178.  
  1179. RFC 998                                                       March 1987
  1180.  
  1181.  
  1182. NOTES:
  1183.  
  1184.    <1>  When the buffer size is large, the variances in the round trip
  1185.    delays of many packets may cancel each other out; this means the
  1186.    variance value need not be very big.  This expectation will be
  1187.    explored in further testing.
  1188.  
  1189.  
  1190.  
  1191.  
  1192.  
  1193.  
  1194.  
  1195.  
  1196.  
  1197.  
  1198.  
  1199.  
  1200.  
  1201.  
  1202.  
  1203.  
  1204.  
  1205.  
  1206.  
  1207.  
  1208.  
  1209.  
  1210.  
  1211.  
  1212.  
  1213.  
  1214.  
  1215.  
  1216.  
  1217.  
  1218.  
  1219.  
  1220.  
  1221.  
  1222.  
  1223.  
  1224.  
  1225.  
  1226.  
  1227.  
  1228.  
  1229.  
  1230.  
  1231.  
  1232.  
  1233.  
  1234.  
  1235.  
  1236. Clark, Lambert, & Zhang                                        [Page 21]
  1237.  
  1238.